package com.xli.organ.user.frameuserrolerelation.mapper;

import com.xli.organ.user.frameuserrolerelation.entity.FrameUserRoleRelation;
import com.xli.organ.user.frameuserrolerelation.entity.UserRoleCache;
import org.mapstruct.Mapper;
import org.mapstruct.ReportingPolicy;
import org.mapstruct.factory.Mappers;

import java.util.List;

@Mapper(unmappedTargetPolicy = ReportingPolicy.IGNORE)
public interface IUserRoleCacheMapper {

    IUserRoleCacheMapper INSTANCE = Mappers.getMapper(IUserRoleCacheMapper.class);

    UserRoleCache toCacheEntity(FrameUserRoleRelation frameUserRoleRelation);

    List<UserRoleCache> toCacheList(List<FrameUserRoleRelation> frameUserRoleRelationList);

    List<FrameUserRoleRelation> toEntityList(List<UserRoleCache> userRoleCacheList);
}
